#define _CRT_SECURE_NO_WARNINGS 
#include<iostream>
#include<cmath>
using namespace std;

class Location
{
	friend double distance(Location&p1,Location&p2);
public:
	Location(double x1=0, double y1=0)
		:x(x1)
	    , y(y1)
	{}
	double Getx()
	{
		return x;
	}
	double Gety()
	{
		return y;
	}
private:
	double x;
	double y;

};
double distance(Location& p1, Location& p2)
{
	double x1 = p1.Getx(), y1 = p1.Gety();
	double x2 = p2.Getx(), y2 = p2.Gety();
	double ret;
      
	ret = sqrt((x1 - x2)*(x1-x2)+(y1-y2)*(y1-y2));
	return ret;
}
class Student
{
public:
	Student(double score1=60)
		:score(score1)
	{
		
         account(score);

	}
	void account(double a)
	{
		 n++;
		 total_score += a;
	}

	static double sum()
	{
		return total_score;
	}
	static double ave()
	{
		return (total_score/n);
	}
	//Student(double score1 = 60.0)
	//	:score(score1)
	//{
	//	n++;
	//	total_score += score;
	//   
	//}
	//double ave()
	//{
	//	return (total_score/n);
	//}
	//double get()
	//{
	//	return  n;
	//}
	//double sum()
	//{
	//	return total_score;
	//}
private:
	double score;
	static double total_score;
	static double n;
	
};

double Student::n = 0;
double Student::total_score = 0;

int main()
{
	
	/*Location a(-1.1,-2.1);
	Location b(-1.1,2.1);

	cout<<distance(a, b) <<endl;*/

	Student a1(60);
	Student a2(50);
	Student a3(55.2);

	cout<<Student::ave()<<endl;
	cout << Student::sum() << endl;

	return 0;
}